package com.newvpn.fastbest.zenith.net;

import com.newvpn.fastbest.zenith.beans.netbeans.AddTimeBean;
import com.newvpn.fastbest.zenith.beans.netbeans.BaseResponse;
import com.newvpn.fastbest.zenith.beans.netbeans.EncryBean;
import com.newvpn.fastbest.zenith.beans.netbeans.PingBean;
import com.newvpn.fastbest.zenith.beans.netbeans.StartBean;
import com.newvpn.fastbest.zenith.beans.netbeans.UserInfo;
import com.newvpn.fastbest.zenith.beans.netbeans.VersionBean;
import com.newvpn.fastbest.zenith.beans.reqbeans.ReqAddTimeBean;
import com.newvpn.fastbest.zenith.beans.reqbeans.ReqAdValue;
import com.newvpn.fastbest.zenith.beans.reqbeans.FeedbackBean;
import com.newvpn.fastbest.zenith.beans.reqbeans.NodeBean;

import io.reactivex.rxjava3.core.Observable;
import io.reactivex.rxjava3.core.Single;
import retrofit2.http.Body;
import retrofit2.http.POST;

public interface ApiService {

    @POST("ad/cost")
    Observable<BaseResponse<Void>> postAdCost(@Body ReqAdValue deviceInfo);

    @POST("u/tourist")
    Observable<BaseResponse<UserInfo>> getUserInfo();


    @POST("n/list")
    Single<BaseResponse<EncryBean>> getVPNList();

    @POST("n/server")
    Observable<BaseResponse<EncryBean>> geVPNServerInfo(@Body NodeBean content);

    @POST("s/startConnect")
    Observable<BaseResponse<StartBean>> seesionStart(@Body NodeBean content);

    @POST("s/endConnect")
    Observable<BaseResponse<Void>> seesionEnd(@Body NodeBean content);

    @POST("s/beat")
    Observable<BaseResponse<PingBean>> seesionPing(@Body NodeBean content);

    @POST("sys/suggest")
    Single<BaseResponse<Void>> suggest(@Body FeedbackBean content);

    @POST("sys/release")
    Observable<BaseResponse<VersionBean>> getVersion();

    @POST("sys/ad")
    Observable<BaseResponse<EncryBean>> getAdConfig();


    @POST("s/addConnectTime")
    Observable<BaseResponse<AddTimeBean>> addTime(@Body ReqAddTimeBean content);

}
